import request from '@/utils/request'

const API = '/user/hosp/hospital'

export default {
  getHospitalList(searchObj) {
    return request({
      url: `${API}/list`,
      method: 'get',
      params: searchObj
    })
  },
  findByName(name) {
    return request({
      url: `${API}/${name}`,
      method: 'get'
    })
  },
  show(hoscode) {
    return request({
      url: `${API}/detail/${hoscode}`,
      method: 'get'
    })
  },
  findDepartment(hoscode) {
    return request({
      url: `/user/hosp/department/all/${hoscode}`,
      method: 'get'
    })
  }
}
